<h2><?=$this->tarefa->getNome()?></h2>

<p>Nome: <?=$this->tarefa->getNome()?></p>
<p>Custo: <?=$this->tarefa->getCusto()?></p>
<p>Passo: <?=$this->tarefa->getPasso()?>%</p>

<?if(!$this->tarefa->getRequisitos()->isEmpty()):?>
<h3>Requisitos</h3>
<ul>
<?foreach($this->tarefa->getRequisitos() as $requisito):?>
    <li>Requisito: <?=$this->partial('_partials/'.end(explode('\\', get_class($requisito))).'.phtml', array('requisito'=>$requisito));?></li>
<?endforeach;?>
</ul>
<?endif;?>

<?if(!$this->tarefa->getBeneficios()->isEmpty()):?>
<h3>Beneficios</h3>
<ul>
<?foreach($this->tarefa->getBeneficios() as $beneficio):?>
    <li>Benefício: <?=$this->partial('_partials/'.end(explode('\\', get_class($beneficio))).'.phtml', array('beneficio'=>$beneficio));?></li>
<?endforeach;?>
</ul>
<?endif;?>

<a href="<?=$this->url(array('controller'=>'tarefas','action'=>'index'));?>">Listar</a> | 
<a href="<?=$this->url(array('controller'=>'tarefas','action'=>'edit','id'=> $this->tarefa->getId()));?>">Editar</a> |
<a class="confirm" href="<?=$this->url(array('controller'=>'tarefas','action'=>'delete','id'=> $this->tarefa->getId()));?>">Excluir</a>